package com.pjhouse.core.common.domain;

public enum Status {

	Default(0, "无效"),Invalid(-1, "无效");
	
	private final int status;
	private final String desc;
	
	private Status(final int status, final String desc){
		this.status = status;
		this.desc = desc;
	}
	
	public static Status get(int status){
		for (Status s : Status.values()) {
			if(s.status == status)
				return s;
		}
		return Status.Default;
	}
	
	public int getValue(){
		return this.status;
	}
	
	public String getDesc(){
		return this.desc;
	}
}
